package com.qms.repast.ui.base;

import android.support.annotation.LayoutRes;
import android.support.annotation.Nullable;

import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;

import java.util.List;

/**
 * @author 泅渡者
 * @date 2018/7/16 0016
 * @describe:
 */
public abstract class BaseCompatAdapter<T, K extends BaseViewHolder> extends BaseQuickAdapter<T,
		K> {

	public BaseCompatAdapter (@LayoutRes int layoutResId, @Nullable List<T> data) {
		super(layoutResId, data);
		init();
	}

	public BaseCompatAdapter (@Nullable List<T> data) {
		super(data);
		init();
	}

	public BaseCompatAdapter (@LayoutRes int layoutResId) {
		super(layoutResId);
		init();
	}

	private void init () {
		setEnableLoadMore(true);
		openLoadAnimation();//开启默认动画载入（仅开启加载新item时开启动画）
	}
}
